import redis
import time

if __name__ == '__main__':
    cli = redis.StrictRedis(
        host="192.168.189.137",
        port=6379,
        db=3
    )
# 3 号 数据库准备就绪
    cli.flushdb()
# 无序集合没有修改的功能 且没有权重
# 增
    cli.sadd("set1", "a", "b", "c")
# 查 查询结果返回所有值
    print(cli.smembers("set1"))
# 删
    cli.srem("set1", "a")
    print(cli.smembers("set1"))



